import request from '@/utils/request'
import qs from 'qs'

const headers = {
  'Content-Type': 'application/x-www-form-urlencoded'
}

//获取token
export function getToken() {
  return localStorage.getItem(tokenKey);
};
//设置token
export function setToken(token) {
  return localStorage.setItem(tokenKey, token);
};
//删除token
export function removeToken() {
  return localStorage.removeItem(tokenKey);
};
//用户列表
export function userList(data) {
  return request({
    url: '/jguser/userList',
    method: 'post',
    data: qs.stringify(data),

  })
}
// 锁定解锁
export function lockList(data) {
  return request({
    url: '/jguser/lockUser',
    method: 'post',
    data: qs.stringify(data),
  })
}
// 删除
export function delList(data) {
  return request({
    url: '/jguser/deleUser',
    method: 'post',
    data: qs.stringify(data),
  })
}

// 审核
export function reviewList(data) {
  return request({
    url: '/jguser/auditRegisteredUsers',
    method: 'post',
    data: qs.stringify(data),
  })
}
